package com.yunding.exception;

/**
 * <p>
 * 非业务逻辑错误异常，如sql错误或json解析错误
 * </p>
 *
 * @author 杜奕明
 * @date 2019/10/1
 */
public class SystemException extends RuntimeException {

    private String logInfo;

    public SystemException() {
        super();
    }

    public SystemException(Throwable cause) {
        super(cause);
    }

    public SystemException(Throwable cause, Object causeBy) {
        super(cause);
        this.logInfo = cause.getMessage() + " - " + causeBy.toString();
    }

    public SystemException(String message, Object object) {
        super(message);
        this.logInfo = message + " - " + object.toString();
    }

    public SystemException(String message) {
        super(message);
    }

    public SystemException(String message, Throwable cause) {
        super(message, cause);
    }

    protected SystemException(String message, Throwable cause, boolean enableSuppression, boolean writableStackTrace) {
        super(message, cause, enableSuppression, writableStackTrace);
    }
}
